package com.niiwoo.civet.user.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 用户身份信息性别枚举
 */
@Getter
@AllArgsConstructor
public enum UserIdentitySexEnum {


    UNKNOWN((byte) 0,"未知"),
    MALE((byte) 1, "男"),
    FEMALE((byte) 2, "女");

    private Byte value;

    private String desc;

    public static UserIdentitySexEnum of(byte value) {
        for (UserIdentitySexEnum t : values()) {
            if (t.value == value) {
                return t;
            }
        }
        return null;
    }

}
